<form id="edit-form" class="form-horizontal" role="form" data-toggle="validator" method="POST" action="">
    <script type="text/javascript" src="https://api.map.baidu.com/api?v=2.0&ak={:config('site.configgroup')['baidu_ak']}"></script>
    <script type="text/javascript">
        var latitude = {$row.latitude};
        var longitude= {$row.longitude};
    </script>
    <div class="row">
        <div class="col col-xs-12 col-sm-8">
            <div class="form-group">
                <label class="control-label col-xs-12 col-sm-2">{:__('Building_name')}:</label>
                <div class="col-xs-12 col-sm-8">
                    <input id="c-building_name" data-rule="required" class="form-control" name="row[building_name]" type="text" value="{$row.building_name|htmlentities}">
                </div>
            </div>
            <div class="form-group">
                <label class="control-label col-xs-12 col-sm-2">地址:</label>
                <div class="col-xs-12 col-sm-7">
                    <input id="c-address" data-rule="required" class="form-control" name="row[address]" type="text" value="{$row.address}">
                </div>
                <div class="col-xs-12 col-sm-1">
                    <input type="button" class="btn btn-primary btn-embossed" value="定位" id="btn-map" />
                </div>
            </div>
            <div class="form-group">
                <label class="control-label col-xs-12 col-sm-2">商业:</label>
                <div class="col-xs-12 col-sm-8">
                    <input id="c-business" data-rule="" class="form-control" name="row[business]" type="text" value="{$row.business}">
                </div>
            </div>
            <div class="form-group">
                <label class="control-label col-xs-12 col-sm-2">{:__('Latitude')}:</label>
                <div class="col-xs-12 col-sm-8">
                    <input id="c-latitude" data-rule="required" class="form-control" name="row[latitude]" type="number" value="{$row.latitude|htmlentities}">
                </div>
            </div>
            <div class="form-group">
                <label class="control-label col-xs-12 col-sm-2">{:__('Longitude')}:</label>
                <div class="col-xs-12 col-sm-8">
                    <input id="c-longitude" data-rule="required" class="form-control" name="row[longitude]" type="number" value="{$row.longitude|htmlentities}">
                </div>
            </div>
            <div class="form-group">
                <label class="control-label col-xs-12 col-sm-2">{:__('Areacode')}:</label>
                <div class="col-xs-12 col-sm-8">
                    <div class='control-relative'><input id="c-areaName" data-rule="required" class="form-control" data-toggle="city-picker" name="row[areaName]" type="text" value="{$row.areaName|htmlentities}"></div>
                </div>
            </div>
            <input id="c-areaCode" type="hidden" name="row[areaCode]" value="{$row.areaCode|htmlentities}" />
            <div class="form-group">
                <label class="control-label col-xs-12 col-sm-2">{:__('Alias_name1')}:</label>
                <div class="col-xs-12 col-sm-8">
                    <input id="c-alias_name1" class="form-control" name="row[alias_name1]" type="text" value="{$row.alias_name1|htmlentities}">
                </div>
            </div>
            <div class="form-group">
                <label class="control-label col-xs-12 col-sm-2">{:__('Alias_name2')}:</label>
                <div class="col-xs-12 col-sm-8">
                    <input id="c-alias_name2"  class="form-control" name="row[alias_name2]" type="text" value="{$row.alias_name2|htmlentities}">
                </div>
            </div>
            <div class="form-group">
                <label class="control-label col-xs-12 col-sm-2">{:__('Second_count')}:</label>
                <div class="col-xs-12 col-sm-8">
                    <input id="c-second_count" readonly data-rule="required" class="form-control" name="row[second_count]" type="number" value="{$row.second_count|htmlentities}">
                </div>
            </div>
            <div class="form-group">
                <label class="control-label col-xs-12 col-sm-2">{:__('Second_onsell')}:</label>
                <div class="col-xs-12 col-sm-8">
                    <input id="c-second_onsell" readonly data-rule="required" class="form-control" name="row[second_onsell]" type="number" value="{$row.second_onsell|htmlentities}">
                </div>
            </div>
            <div class="form-group">
                <label class="control-label col-xs-12 col-sm-2">合并到:</label>
                <div class="col-xs-12 col-sm-8">
                    <input id="c-merge" class="form-control" name="row[merge]" type="text" />
                </div>
            </div>
        </div>
        <div class="col-xs-12 col-sm-4">
            <div id="cop-map-container" style="height:480px;width:360px"></div> 
        </div>
    </div>
    <div class="form-group layer-footer">
        <label class="control-label col-xs-12 col-sm-2"></label>
        <div class="col-xs-12 col-sm-8">
            <button type="submit" class="btn btn-success btn-embossed disabled">{:__('OK')}</button>
            <button type="reset" class="btn btn-default btn-embossed">{:__('Reset')}</button>
        </div>
    </div>
</form>
